﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;

namespace HOOMT.Util
{
    class FileUtil
    {
        public static void WriteFile(string path, string text)
        {
            FileStream fs = null;
            StreamWriter sw = null;
            try
            {
                fs = new FileStream(path, FileMode.Create);

                sw = new StreamWriter(fs, Encoding.UTF8);
                sw.Write(text);
            }
            catch (System.Exception ex)
            {
                throw ex;

            }
            finally
            {
                sw.Close();
                fs.Close();
            }


        }
    }
}
